<!doctype html>

<html lang="zh-CN">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Vue选项式API模板</title>
    <script src="https://unpkg.com/vue@3.4.0"></script>
  </head>
  <body>
    <div id="app">
      <!-- Vue模板内容区域 -->
      <h1>{{ title }}</h1>
      <p>{{ message }}</p>
    </div>

    <script>
      const { createApp } = Vue

      const App = {
        data() {
          return {
            title: 'Vue选项式API',
            message: '这是一个Vue应用示例'
          }
        },
        methods: {
          // 方法定义
        },
        computed: {
          // 计算属性
        },
        mounted() {
          // 生命周期钩子
        }
      }

      createApp(App).mount('#app')
    </script>
  </body>
</html>
